package com.yueqian.system.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.yueqian.system.entity.User;
import com.yueqian.system.entity.UserRole;
import com.yueqian.system.vo.req.UserRoleReqVO;

import java.util.List;

public interface UserRoleService extends IService<UserRole> {
	Page<User> selectPageData(UserRoleReqVO userRoleReqVO);

	void delete(List<Long> userIds, Long roleId);

	/**
	 * 角色分配给用户
	 *
	 * @param userIds
	 * @param roleId
	 */
	Boolean add(List<Long> userIds, Long roleId);


	/**
	 * 用户分配角色
	 *
	 * @param userId
	 * @param roleIds
	 */
	Boolean add(Long userId, List<Long> roleIds);


	List<UserRole> selectListData(UserRoleReqVO reqVO);

}
